import  Cookies from 'js-cookie'

const TokenKey = 'learning-Token'

const users='users'

export function setuser(val:any){
  return Cookies.set(users,val)
}

export function getuser(){
  return Cookies.get(users)
}


export function getToken() {
  return Cookies.get(TokenKey)
}

export function setToken(token:string) {
  return Cookies.set(TokenKey, token)
}

export function removeToken() {
  return Cookies.remove(TokenKey)
}


export function getCookie(key:string) {
  return Cookies.get(key)
}

export function setCookie(key:string,token:string) {
  return Cookies.set(key, token)
}

export function removeCookie(key:string) {
  return Cookies.remove(key)
}
